:Init
@setlocal ENABLEEXTENSIONS ENABLEDELAYEDEXPANSION
@pushd %~dp0
@prompt $_
@echo off

if "%1" == "/?" goto Usage
if "%1" == "-?" goto Usage
goto :Install

:Usage
@echo.
@echo Enables the Remote Adminsitration features.
@echo.
@echo WEBADMIN.SETUP
@echo.
@goto :eof

:Install
start /w ocsetup IIS-ManagementService
reg add HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WebManagement\Server /v EnableRemoteManagement /t REG_DWORD /d 1 /f
net start wmsvc
sc config WMSVC start= auto
@goto :End

:End
@echo Completed.
exit /b /0
goto :eof
